<template>
  <div class="group_wrap" >
    <div class="slides">
    <ul id="containers">
      <li type="ment" tid="newsid" v-for="(item,index) in newsData2"  @click="onItem(item.newsId)">

          <div class="leftLayout">
            <p tid="title_name">{{item.title}}</p>
            <p>
              <span tid="time">{{item.publishDate}}</span>
              <span tid="address">长沙工商局</span>
            </p>
          </div>

         <div class=rightLayout  tid="imgbox" style="background:url('../../static/zhengWu/pic_08.jpg') no-repeat center; ">

        </div>
      </li>
      </ul>
    </div>
  </div>
</template>


<style>
  .group_wrap ul {
    padding: 0.2rem 0 5% 0.3rem;
    list-style: none;
  }
  .slides ul li:first-child{
    padding-top:0 !important;
  }
  .group_wrap ul li[type='ment'] {

    border-bottom: 1px solid #eee;
    padding: 0.25rem 0.3rem 0.25rem 0rem;
  }
  .textContent{
    display: flex;
    display: -webkit-flex;
    flex-flow: row;
    justify-content: space-between;
  }
  .slides ul li[type='ciate'] p:last-child {
    color: #999;
    font-size: 0.18rem;
  }

  .group_wrap ul li[type='ment'] .leftLayout {


  }

  .group_wrap ul li[type='ment'] .leftLayout p:first-child {
    margin-bottom: 0.5rem;
    display: -webkit-box;
    text-overflow: ellipsis;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    width: 95%;
    font-size:0.3rem;

  }

  .group_wrap ul li[type='ment'] .leftLayout p:last-child span {
    color: #999;
    font-size: 0.18rem;
    margin-right: 0.3rem;
  }

  .group_wrap ul li[type='ment'] .rightLayout {
    width: 4.5rem;
    align-self: stretch;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-size: 100% 100% !important;
  }

  .group_wrap ul li[type='ment'] .rightLayout img {
    width: 100%;
  }
</style>


<script>
  export default{
    props:['cityid','newsData2'],
    data(){
      return{}
    },
    methods:{
      onItem(ids){
        this.$router.push({path:'/newdatails',query: { id:ids }});
      }
    },
    watch:{
      cityid:(newVal)=>{
        console.log(newVal)
      }
    },
   mounted(){

   }
  }
</script>
